<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<style type="text/css">
			div{
				color: blue;
				text-decoration: underline;
				cursor: pointer;
			}
		</style>
	</head>
	<body>
		<div>百度一下</div>
	</body>
	
	<script type="text/javascript">
		var div=document.getElementsByTagName("div")[0];
		div.onclick=()=>{
			location="https://www.baidu.com/";
		}
	</script>
</html>
